package com.cn.study007;

import java.util.Scanner;

/**
 * @author lw
 * @ClassName Test7007.java
 * @Description
 * @createTime 2023年05月14日 15:52:00
 */
public class Test7007 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        double score = 0;      //成绩

        for (int i = 1; i <= 3; i++) {
            System.out.println("请输入第" + i + "个班级的成绩");
            double sum = 0;       //总成绩
            for (int j = 1; j <= 4; j++) {
                System.out.print("第" + j + "位学员的成绩:");
                score = sc.nextDouble();
                sum = sum + score;
            }
            double avg = sum / 4;
            System.out.println("参赛学员的平均分是：" + avg+"\n");
        }
    }
}
